package com.linyx.simpleboot.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import com.linyx.simpleboot.domain.User;
import com.linyx.simpleboot.mapper.UserMapper;

@RestController
@RequestMapping("/user")
public class UserController {

	@Autowired
	private UserMapper userMapper;
	
	@PostMapping(value="/queryUser")
	public List<User> queryUser(){
	List<User> users = userMapper.queryUserList();
	return users;
	}
}
